////////////////////////////////////////////////////////////////////////////////
// Copyright 2006 CORE Solutions Limited
// All rights reserved.
// PROPRIETARY AND CONFIDENTIAL INFORMATION.
// Use is subject to license terms.
//
// FUNCTION ID      :   SystemConstantsQuery.java
// AUTHOR           :   ric.yik
// DATE CREATE      :   Feb 7, 2006
// DESCRIPTION      :   
//                  :   
//                  :   
//                  :   
//
// MODIFICATION HISTORY:
// DATE         AUTHOR          VERSION NO.         COMMENT
// -----------  --------------  ------------------  -------------------
// Feb 7, 2006      ric.yik         1.0                 source is created.
//
//
//
////////////////////////////////////////////////////////////////////////////////

package com.erp.app.common.query;

public class SystemConstantsQuery implements QueryObject {

    private String type;

    private String order;

    public SystemConstantsQuery() {
        super();
        this.setOrder("ORDER_SEQ");
    }

    public String getType() {
        return type;
    }

    public SystemConstantsQuery setType(String type) {
        this.type = type;
        return this;
    }

    public String getOrder() {
        return order;
    }

    public SystemConstantsQuery setOrder(String order) {
        this.order = order;
        return this;
    }

    public String toQuery() {
        return "SELECT CONSTANT_CODE, CONSTANT_NAME FROM T_SYS_CONSTANTS WHERE TYPE = '" + this.getType() + "' ORDER BY " + this.getOrder();
    }

    public String toString() {
        return this.toQuery();
    }

}
